//创建对象
//构造函数
function student(name){
    this.name=name;
    this.hello=function(){
        alert('Hello,'+this.name+'!')
    }
}
var ljy=new student('辣椒油')
console.log(ljy.name);    //辣椒油
console.log(ljy.hello());   //Hello，辣椒油!